<ui:composition
    xmlns="http://www.w3.org/1999/xhtml"
    xmlns:ui="http://java.sun.com/jsf/facelets"
    xmlns:p="http://primefaces.org/ui"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core">

    <p:dialog id="message2"
              header="Progress Interview Dialog"
              widgetVar="dlg_interview"
              modal="true"
              resizable="false"
              width="960">
        <h:form id="frm-progress-interview">
            <div id="combobox">
                <p class="p-left">
                    <label>Status :</label>
                <h:selectOneMenu id="cbo-status"
                                 value="#{myInterviewBean.selectedInterview.status}"
                                 styleClass="text-input medium-input"
                                 rendered="#{myInterviewBean.selectedInterview.status != 99}">
                    <f:selectItem itemLabel="Not In Progress" itemValue="0"/>
                    <f:selectItem itemLabel="Selected" itemValue="100" />
                    <f:selectItem itemLabel="Rejected" itemValue="-100" />
                    <p:ajax process="@this" listener="#{myInterviewBean.changeStatus}"
                            update="@form :frm-interview :growl"/>
                    <f:param name="id" value="#{myInterviewBean.selectedInterview.interviewID}"/>
                </h:selectOneMenu>
                <h:outputText value="Postponed"
                              rendered="#{myInterviewBean.selectedInterview.status == 99}"/>
                </p>
            </div>
            <div class="content-box column-left">
                <div class="content-box-header">
                    <h3>Applicant Information</h3>
                </div> <!-- End .content-box-header -->

                <div class="content-box-content">
                    <div class="tab-content default-tab v-scroll">
                        <h:panelGroup rendered="#{not myInterviewBean.selectedInterview.applicant.gender}">
                            <div class="female"/>
                        </h:panelGroup>
                        <h:panelGroup rendered="#{myInterviewBean.selectedInterview.applicant.gender}">
                            <div class="male"/>
                        </h:panelGroup>
                        <div class="personal-info">
                            <h4>#{myInterviewBean.selectedInterview.applicant.firstName}
                                #{myInterviewBean.selectedInterview.applicant.lastName}
                                - #{myInterviewBean.selectedInterview.applicant.applicantID}</h4>
                            <p>
                                <strong>Gender: </strong>
                                #{applicantBean.gender(myInterviewBean.selectedInterview.applicant)}
                            </p>
                            <p>
                                <strong>Date Of Birth: </strong>
                                #{calendarMB.titleFormat(myInterviewBean.selectedInterview.applicant.dob)}
                            </p>
                        </div>
                        <div class="contact-info">
                            <p>
                                <strong>Phone Number: </strong>
                                #{myInterviewBean.selectedInterview.applicant.phoneNumber}
                            </p>
                            <p>
                                <strong>Email: </strong>
                                #{myInterviewBean.selectedInterview.applicant.email}
                            </p>
                            <p>
                                <strong>Address: </strong>
                                #{myInterviewBean.selectedInterview.applicant.address}
                            </p>
                        </div>
                        <div class="recruitment-info">
                            <p>
                                <strong>Salary Requirement: </strong>
                                $ #{myInterviewBean.selectedInterview.applicant.salaryRequirement}
                            </p>
                            <p>
                                <strong>Language: </strong>
                                #{myInterviewBean.selectedInterview.applicant.language}
                            </p>
                            <p>
                                <strong>Year Of Experience: </strong>
                                #{myInterviewBean.selectedInterview.applicant.yearOfExperience}
                            </p>
                            <p>
                                <strong>Degree: </strong>
                                #{myInterviewBean.selectedInterview.applicant.degree}
                            </p>
                            <p>
                                <strong>Skill: </strong>
                                #{myInterviewBean.selectedInterview.applicant.skill}
                            </p>
                            <p>
                                <strong>Award: </strong>
                                #{myInterviewBean.selectedInterview.applicant.award}
                            </p>
                        </div>
                    </div> <!-- End #tab3 -->
                </div> <!-- End .content-box-content -->
            </div> <!-- End .content-box -->
            <h:panelGroup id="frm-right">
                <div class="content-box column-right">
                    <div class="content-box-header"> <!-- Add the class "closed" to the Content box header to have it closed by default -->
                        <h3>Vacancy Information</h3>
                    </div> <!-- End .content-box-header -->

                    <div class="content-box-content">
                        <div class="tab-content default-tab v-scroll">
                            <h4 class="vacancy-title">#{myInterviewBean.selectedInterview.vacancy.title} -
                                #{myInterviewBean.selectedInterview.vacancy.vacancyID}</h4>
                            <div class="block">
                                <p>
                                    <strong>Department: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.department.name}
                                </p>
                                <p>
                                    <strong>Number Requirement: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.numberRequirement}
                                </p>
                                <p>
                                    <strong>Position: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.position}
                                </p>
                            </div>
                            <div class="block">
                                <p>
                                    <strong>Working Place: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.workingPlace}
                                </p>
                                <p>
                                    <strong>Work Type: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.workType}
                                </p>
                                <p>
                                    <strong>Minimum Salary: </strong>
                                    $ #{myInterviewBean.selectedInterview.vacancy.minimumSalary}
                                </p>
                                <p>
                                    <strong>Maximum Salary: </strong>
                                    $ #{myInterviewBean.selectedInterview.vacancy.maximumSalary}
                                </p>
                            </div>
                            <div class="block">
                                <p>
                                    <strong>Description: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.description}
                                </p>
                                <p>
                                    <strong>Skill Requirement: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.skillRequirement}
                                </p>
                                <p>
                                    <strong>Entitlement: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.entitlement}
                                </p>
                            </div>
                            <div class="block">
                                <p>
                                    <strong>Minimum Age: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.minimumAge}
                                </p>
                                <p>
                                    <strong>Maximum Age: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.maximumAge}
                                </p>
                                <p>
                                    <strong>Gender: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.gender}
                                </p>
                            </div>
                            <div class="block">
                                <p>
                                    <strong>Degree: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.degree}
                                </p>
                                <p>
                                    <strong>Year Of Experience: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.yearOfExperience}
                                </p>
                                <p>
                                    <strong>Probationary Period: </strong>
                                    #{myInterviewBean.selectedInterview.vacancy.probationaryPeriod}
                                </p>
                                <p>
                                    <strong>Deadline: </strong>
                                    #{calendarMB.dateFormat(myInterviewBean.selectedInterview.vacancy.deadline)}
                                </p>
                            </div>
                        </div> <!-- End #tab3 -->
                    </div> <!-- End .content-box-content -->
                </div> <!-- End .content-box -->
            </h:panelGroup>
        </h:form>
    </p:dialog>
</ui:composition>